-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Redirect already created users to the dashboard #653
Merged
spaceo
merged 8 commits into
danskernesdigitalebibliotek:develop
from
reload:DDFLSBP-229-brugeroprettelse-laner-der-er-oprettet-i-forvejen-vises-en-fejlside
Nov 5, 2023
Merged
Redirect already created users to the dashboard #653
spaceo
merged 8 commits into
danskernesdigitalebibliotek:develop
from
reload:DDFLSBP-229-brugeroprettelse-laner-der-er-oprettet-i-forvejen-vises-en-fejlside
Nov 5, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
We want to have a similar interface for querying openid data as we have for the other APIS - starting with the useUserinfo hook.
They are going to be used for the "redirect users to the dashboard if they are already created" - functionality.
to the dashboard.
It is a handy helper that is needed globally. Also changed it to return all the properties from react-query in case we need them in the future.
spaceo
force-pushed
the
DDFLSBP-229-brugeroprettelse-laner-der-er-oprettet-i-forvejen-vises-en-fejlside
branch
from
November 1, 2023 21:23
852623f
to
5c743c6
Compare
spaceo
changed the title
Ddflsbp 229 brugeroprettelse laner der er oprettet i forvejen vises en fejlside
Redirect already created users to the dashboard
Nov 2, 2023
And put it where the other clients reside. No reason to do it differntly than the others...
spaceo
force-pushed
the
DDFLSBP-229-brugeroprettelse-laner-der-er-oprettet-i-forvejen-vises-en-fejlside
branch
from
November 2, 2023 08:19
c883f54
to
99966a7
Compare
kasperg
approved these changes
Nov 2, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 nice. I especially enjoyed the refactorings.
There are some things that I think warrants a second thought.
spaceo
force-pushed
the
DDFLSBP-229-brugeroprettelse-laner-der-er-oprettet-i-forvejen-vises-en-fejlside
branch
from
November 5, 2023 16:10
c9a0f46
to
fb427c6
Compare
Like we do with other query hooks. Also renamed useGetUserInfo.ts to seUserInfo.ts - no need to use a different filename for the hook.
We should call the file the same as the error type.
spaceo
force-pushed
the
DDFLSBP-229-brugeroprettelse-laner-der-er-oprettet-i-forvejen-vises-en-fejlside
branch
from
November 5, 2023 16:45
fb427c6
to
7c141f8
Compare
spaceo
merged commit Nov 5, 2023
94615ad
into
danskernesdigitalebibliotek:develop
9 of 10 checks passed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Link to issue
https://reload.atlassian.net/browse/DDFLSBP-229
Description
Users that already have been created should be redirected to the dashboard.
The CreatePatron component looks at the userinfo and checks if the current agency id exists in the
agencies
array.Additional comments or questions
This should be merged before it's dpl-cms sibling.